getSavDetail();
function getSavDetail() {
  //获取当前商品id
  var id = location.search;
  id = id.substr(1);
  // console.log(id);
  $.ajax({
    type: 'get',
    url: 'http://193.112.55.79:9090/api/getmoneyctrlproduct',
    dataType: 'json',
    data: { productid: id },
    success: function (res) {
      console.log(res);
      var str = template('Temp', res);
      $('.Sav_main').html(str);
    }
  })
}

//返回省钱控主页面
$('#oth').on('click', function () {
  location.href = './SaveMoney.html';
})